Ext.define('appmod.view.knowledge.AttachmentDashboard', {
    extend: 'Ext.panel.Panel',
    alias: [
		'widget.knowledge.attachmentdashboard',
		'widget.knowledge-attachmentdashboard'],
    region : 'center',
    layout : {
		type:'border'
	},
	requires: [
		'appmod.view.knowledge.category.TreeGrid',
		'appmod.view.knowledge.BigView'
	],	
	border : false,
	margins:"5 5 5 5",

	constructor: function (config) {
		
		if (config.fieldStores) {
			this.stores = config.stores;
		}
        this.callParent(arguments);
     },	

    initComponent: function() {
        var me = this;
		
		// --- binding store ---
		var dsCategory = me.stores['category'];
	
        Ext.applyIf(me,{
			items:[
				{
					store:dsCategory,
			        rootVisible: true,
			        useArrows: true,
			        frame: true,
					title:'文件分类',
					collapsible:true,					
					xtype:'knowledge.tree.grid',
					region:'west',
					split:true,
					margins:"5 0 5 5",
					width:200
				},
				{
					xtype:'knowledge.content.bigview',
					region:'center',
					border:true,	
                    collapsed: false,
					autoScroll:true,
					margins:"5 5 5 0"
										
				}
			]
			
		});

        me.callParent(arguments);

    }
});